from typing import Any, Optional, Dict

from fastapi import HTTPException
from starlette import status

from fastapi import HTTPException


class SnowyPermissionDenied(HTTPException):
    def __init__(
            self,
            message: Any = 'You do not have permission to perform this action',
            headers: Optional[Dict[str, Any]] = None,
            status_code=status.HTTP_403_FORBIDDEN
    ) -> None:
        super().__init__(status_code=status_code, detail=message)
        self.headers = headers


class SnowyNotFound(HTTPException):
    def __init__(
            self,
            message: Any = 'Not found',
            headers: Optional[Dict[str, Any]] = None,
    ) -> None:
        super().__init__(status_code=status.HTTP_404_NOT_FOUND, detail=message)
        self.headers = headers
